

package org.afem.java.basics.samples;

import org.afem.java.basics.entities.Nif;

/*
 * @author Andrés Felipe España
 */
public class testNif {
   public static void main(String arg[]){   
       int dni = 87654321;
       char letra = 'X';
       
       //nuevo nif1
       Nif nif1 = new Nif();
       System.out.println("NIF: " + nif1);
       
       //nuevo nif2
       Nif nif2 = new Nif(dni, letra);
       System.out.println("NIF: " + nif2);
       
       //comparamos
       if(nif1.equals(nif2)) {
           System.out.println("Los NIF son iguales.");
       } else {
           System.out.println("Los NIF son diferentes.");
       }
   }
}
